package com.exam.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.experimental.Accessors;

@TableName("student")
@Data
@AllArgsConstructor
@NoArgsConstructor
@Accessors(chain = true)
public class Student {
    @TableId(value = "studentId")
    private Long studentId;

    @TableField("studentName")
    private String studentName;

    private String grade;

    private String major;

    private String clazz;

    private String institute;

    private String tel;

    private String email;

    private String pwd;

    @TableField("cardId")
    private Long cardId;

    @TableField(value = "sex")
    private Integer sex;

    private Integer role;

    public Student(Long studentId, String studentName, String tel, String pwd, Integer role) {
        this.studentId = studentId;
        this.studentName = studentName;
        this.tel = tel;
        this.pwd = pwd;
        this.role = role;
    }
}